package com.xnyzc.lhy.resource.service.impl.worksheet;

import com.xnyzc.lhy.common.entity.DiDiRv;
import com.xnyzc.lhy.common.entity.WorksheetRv;
import com.xnyzc.lhy.order.entity.param.synchronization.ChangePriceParam;
import com.xnyzc.lhy.resource.entity.worksheet.param.*;
import com.xnyzc.lhy.resource.entity.worksheet.param.heli.FromHeliWorksheetParam;
import com.xnyzc.lhy.resource.feign.worksheet.IFWorksheetService;
import com.xnyzc.lhy.resource.service.worksheet.WorksheetService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 工单信息表 服务实现类
 * </p>
 *
 * @author haoyfa
 * @since 2019-11-04
 */
@Slf4j
@Service
public class WorksheetServiceImpl implements WorksheetService {

    @Autowired
    IFWorksheetService iFWorksheetService;

    @Override
    public WorksheetRv cancelOrder(WorksheetCancelOrderParam worksheetCancelOrderParam) {
        return iFWorksheetService.cancelOrder(worksheetCancelOrderParam);
    }

    /**
     * 关闭订单
     * @param worksheetCloseOrderParam
     * @return
     */
    @Override
    public DiDiRv getCloseOrder(WorksheetCloseOrderParam worksheetCloseOrderParam) {
        return iFWorksheetService.getCloseOrder(worksheetCloseOrderParam);
    }

    /**
     * 3.订单改价接口
     *
     * @param priceParam
     * @return
     */
    @Override
    public DiDiRv getChangePrice(ChangePriceParam priceParam) {
        return iFWorksheetService.getChangePrice(priceParam);
    }

    /**
     * 退款接口
     *
     * @param priceParam
     * @return
     */
    @Override
    public DiDiRv getBillRefund(WorksheetGetBillRefundParam priceParam) {
        return iFWorksheetService.getBillRefund(priceParam);
    }

    /**
     * 免单接口
     *
     * @param worksheetFreeChargeParam
     * @return
     */
    @Override
    public DiDiRv getFreeCharge(WorksheetFreeChargeParam worksheetFreeChargeParam) {
        return iFWorksheetService.getFreeCharge(worksheetFreeChargeParam);
    }

    /**
     * 更新工单状态
     * @param worksheetUpdateWorksheetParam
     * @return
     */
    @Override
    public WorksheetRv updateWorksheet(WorksheetUpdateWorksheetParam worksheetUpdateWorksheetParam) {
        return iFWorksheetService.updateWorksheet(worksheetUpdateWorksheetParam);
    }

    /**
     * 获取订单信息
     * @param worksheetGetOrderPersonalDetailParam
     * @return
     */
    @Override
    public WorksheetRv getOrderPersonalDetail(WorksheetGetOrderPersonalDetailParam worksheetGetOrderPersonalDetailParam) {
        return iFWorksheetService.getOrderPersonalDetail(worksheetGetOrderPersonalDetailParam);
    }

    /**
     * 根据手机号获取订单列表
     * @param worksheetgetOrderPersonalListParam
     * @return
     */
    @Override
    public WorksheetRv getOrderPersonalList(WorksheetgetOrderPersonalListParam worksheetgetOrderPersonalListParam) {
        return iFWorksheetService.getOrderPersonalList(worksheetgetOrderPersonalListParam);
    }

    /**
     * 设置司机处罚信息
     * @param worksheetetDriverPenaltyDetailParam
     * @return
     */
    @Override
    public WorksheetRv setDriverPenaltyDetail(WorksheetetDriverPenaltyDetailParam worksheetetDriverPenaltyDetailParam) {
        return iFWorksheetService.setDriverPenaltyDetail(worksheetetDriverPenaltyDetailParam);
    }

    /**
     * 获取司机信息
     * @param worksheetetGetDriverDetailParam
     * @return
     */
    @Override
    public WorksheetRv getDriverDetail(WorksheetetGetDriverDetailParam worksheetetGetDriverDetailParam) {
        return iFWorksheetService.getDriverDetail(worksheetetGetDriverDetailParam);
    }

    /**
     * 创建工单
     * @param fromHeliWorksheetParam
     * @return
     */
    @Override
    public WorksheetRv createWorksheet(FromHeliWorksheetParam fromHeliWorksheetParam) {
        return iFWorksheetService.createWorksheet(fromHeliWorksheetParam);
    }

    @Override
    public WorksheetRv getOrderPersonalStatus(WorksheetGetOrderPersonalStatusParam worksheetGetOrderPersonalStatusParam) {
        return iFWorksheetService.getOrderPersonalStatus(worksheetGetOrderPersonalStatusParam);
    }
}
